package com.online.onlinestudent.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.online.onlinestudent.entity.Course;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

import java.util.List;

@Mapper
public interface CourseMapper extends BaseMapper<Course> {

    @Select("select * from courses where category_id = #{categoryId}")
    List<Course> getCoursesByCategoryId(Long categoryId);
}
